﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web;

namespace LanguageConfigurationSolution
{
    
    /// <summary>
    /// This literal derivative will return the Culture name: nl-NL
    /// </summary>
    public class LanguageCulture : Literal
    {

        public LanguageCulture() 
            : base()
        {
            this.Mode = LiteralMode.Encode;
        }

        protected override void Render(HtmlTextWriter writer)
        {
            this.Text = System.Globalization.CultureInfo.CurrentCulture.Name;
            base.Render(writer);
        }
    }
}
